package com.jfok.server.hibernate.common;

import java.io.Serializable;
import java.util.Date;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import org.hibernate.annotations.GenericGenerator;
import com.jfok.server.common.annotation.FieldDefine;
import com.jfok.server.common.annotation.TableDefine;
import com.jfok.server.hibernate.superclass._InputInfoAbstract;

@Entity
@org.hibernate.annotations.Entity(dynamicUpdate = true)
@TableDefine(group = "文件汇编", id = 9405, title = "文件资料")
public class _Article extends _InputInfoAbstract implements Serializable {

	private static final long serialVersionUID = 1L;
	@Id
	@GeneratedValue(generator = "increment")
	@GenericGenerator(name = "increment", strategy = "increment")
	@FieldDefine(hidden = true, number = 10, title = "序号")
	private Integer tf_articleId;

	@FieldDefine(number = 20, title = "编码")
	@Column(nullable = false, length = 50, unique = true)
	private String tf_code;

	@FieldDefine(number = 30, title = "文件资料名称", nameField = true)
	@Column(nullable = false, length = 50, unique = true)
	private String tf_name;

	@ManyToOne(fetch = FetchType.EAGER, cascade = CascadeType.REFRESH)
	@JoinColumn(name = "tf_articleClassId", nullable = false)
	@FieldDefine(number = 40, title = "资料分类")
	private _ArticleClass tf_ArticleClass;

	@FieldDefine(number = 50, title = "发布单位")
	@Column(length = 50)
	private String tf_publishCompany;

	@FieldDefine(number = 60, title = "发布时间")
	private Date tf_publishDate;

	@FieldDefine(number = 70, title = "制订人")
	@Column(length = 50)
	private String tf_draftsman;

	@FieldDefine(number = 80, title = "版本号")
	@Column(length = 50)
	private String tf_version;

	@FieldDefine(number = 90, title = "有效期")
	@Column(length = 50)
	private String tf_validity;

	@FieldDefine(number = 100, title = "资料状态")
	@Column(length = 50)
	private String tf_state;

	@FieldDefine(number = 200, title = "备注")
	private String tf_remark;

	public _Article() {

	}

	public Integer getTf_articleId() {
		return tf_articleId;
	}

	public void setTf_articleId(Integer tf_articleId) {
		this.tf_articleId = tf_articleId;
	}

	public String getTf_code() {
		return tf_code;
	}

	public void setTf_code(String tf_code) {
		this.tf_code = tf_code;
	}

	public String getTf_name() {
		return tf_name;
	}

	public void setTf_name(String tf_name) {
		this.tf_name = tf_name;
	}

	public _ArticleClass getTf_ArticleClass() {
		return tf_ArticleClass;
	}

	public void setTf_ArticleClass(_ArticleClass tf_ArticleClass) {
		this.tf_ArticleClass = tf_ArticleClass;
	}

	public String getTf_publishCompany() {
		return tf_publishCompany;
	}

	public void setTf_publishCompany(String tf_publishCompany) {
		this.tf_publishCompany = tf_publishCompany;
	}

	public Date getTf_publishDate() {
		return tf_publishDate;
	}

	public void setTf_publishDate(Date tf_publishDate) {
		this.tf_publishDate = tf_publishDate;
	}

	public String getTf_draftsman() {
		return tf_draftsman;
	}

	public void setTf_draftsman(String tf_draftsman) {
		this.tf_draftsman = tf_draftsman;
	}

	public String getTf_version() {
		return tf_version;
	}

	public void setTf_version(String tf_version) {
		this.tf_version = tf_version;
	}

	public String getTf_validity() {
		return tf_validity;
	}

	public void setTf_validity(String tf_validity) {
		this.tf_validity = tf_validity;
	}

	public String getTf_state() {
		return tf_state;
	}

	public void setTf_state(String tf_state) {
		this.tf_state = tf_state;
	}

	public String getTf_remark() {
		return tf_remark;
	}

	public void setTf_remark(String tf_remark) {
		this.tf_remark = tf_remark;
	}

}
